cls
@set JAVAHOME=c:\pierre\soft\j2sdk1.4.2_03
@set VCHOME="C:\Program Files\Microsoft Visual Studio\VC98"
@rem set VCHOME="C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7"
@set MSDKHOME="c:\pierre\soft\Microsoft SDK"
@set CPNMOUSE=C:\pierre\dev\cpnmouse\cpnmouse-api-binary-0.9.1\api

@set LIB=%CPNMOUSE%;%VCHOME%\lib;%MSDKHOME%\lib
@set INCLUDE=
@set CL=-I%CPNMOUSE%\include -I%VCHOME%\include -I%MSDKHOME%\include -I%JAVAHOME%\include -I%JAVAHOME%\include\win32

javac -classpath ../../bin;../../lib/utils.jar -d ../../bin ..\..\src\fr\emn\win32input\jcpnmouse\JCpnMouse.java  
javah -classpath ../../bin fr.emn.win32input.jcpnmouse.JCpnMouse
@del cpnmousewrapper.h
@ren fr_emn_win32input_jcpnmouse_JCpnMouse.h cpnmousewrapper.h

@REM   /LD: make a DLL   /MD: multi-threaded DLL

%VCHOME%\Bin\cl /MD /LD cpnmousewrapper.c cpnmouse_mylapi.c /link user32.lib cpnmouse.lib gdi32.lib setupapi.lib msimg32.lib /machine:x86 /NODEFAULTLIB:libc.lib

move cpnmousewrapper.dll ..

@rem @del *.h
@del *.exp
@del *.lib
@del *.obj
